<template>
  <div>
    <!--商品详情-->
    <div class="common-form mt50">商品详情</div>
    <!-- 图片 -->
    <el-form-item label="图片：" v-if="form.model.content_image_arr.length > 0">
    <div class="item" v-for="(item, index) in form.model.content_image_arr" :key="index">
    
      <ImagePreview :src="item" width="100px" height="100px" />
    </div>
  </el-form-item>
    <!--内容-->
    <el-form-item label="内容：" v-if="form.model.content.length > 0">
        <div class="edit_container">
          <Editor v-model="form.model.content" @change="contentChange"/>
      </div>
    </el-form-item>
  </div>
</template>

<script>
import ImagePreview from '@/components/ImagePreview/index';
import Editor from '@/components/editor/index.vue';
export default {
  components: {
    ImagePreview,
    /*编辑器*/
    Editor
  },
  data() {
    return {
      
    };
  },
  created() {
    console.log(this.form)
  },
  inject: ['form'],
  methods:{

    /*获取富文本框内容*/
    getContent: function() {
      //return this.$refs.ue.getUEContent();
    },

    /*获取富文本内容*/
    contentChange(e){
      this.form.model.content=e;
    }

  }
};
</script>

<style></style>
